@import (once) "../../include/vars";
@import (once) "../../include/mixins";

.bottom-sheet {
    .clear();
    background-color: @white;
    display: block;
    z-index: @zindex-fixed;
    max-width: 360px;
    left: 50%;
    list-style: none inside;
    padding: 0;
    margin: 0 0 0 -50%;
    width: 100%;
    top: 100%;
    position: fixed;
    transition: @transition-base;
    .shadow(2);

    &.wide-sm {
        max-width: 576px;
    }
    &.wide-ld {
        max-width: 640px;
    }
    &.wide-md {
        max-width: 768px;
    }
    &.wide-lg {
        max-width: 992px;
    }
    &.wide {
        max-width: 100%;
    }
}

.bottom-sheet {

    & > .title {
        height: 56px;
        font-size: 16px;
        color: rgba(0,0,0, .87);
    }

    & > li, & > .item {

        font-size: 16px;
        position: relative;
        height: 48px;
        padding-left: 56px;
        display: block;
        cursor: pointer;
        vertical-align: middle;
        line-height: 48px;

        .icon {
            left: 16px;
            position: absolute;
            .square(24, px);
            font-size: 24px;
            line-height: 24px;
            vertical-align: middle;
            text-align: center;
            top: 50%;
            margin-top: -12px;
            opacity: .8;
        }

        &:hover, &.hovered, &.active {
            background-color: @hoverBackground;
        }

    }

    & > .divider {
        height: 1px;
        background-color: @borderColor;
    }

}

.bottom-sheet {
    &.grid-style {
        padding: 16px;

        & > li, & > .item {
            width: 64px;
            height: 72px;
            line-height: normal;
            text-align: center;
            vertical-align: middle;
            display: block;
            float: left;
            margin: 8px;
            padding: 4px;
            font-size: 11px;

            .icon {
                display: block;
                position: relative;
                .square(42, px);
                font-size: 42px;
                margin: 0 0 8px -21px;
                padding: 0;
                top: 0;
                left: 50%;
                line-height: 1;

            }
        }

        & > .divider {
            display: none;
        }
    }
}

.bottom-sheet {
    &.opened {
        transition: @transition-base;
        .translate3d(0, -100%, 0);
    }
}

.bottom-nav ~ .bottom-sheet {
    padding-bottom: 76px;
}